export const commonPage = {
    data() {
        return {
            pageModuleName: 'modulePageRef'
        }
    },
    onLoad: function () {
        this.$nextTick(() => {
            try {
                this.$refs[this.pageModuleName].$onLoad()
            } catch (e) {

            }
        })
    },
    onShow: function () {
        this.$nextTick(() => {
            try {
                this.$refs[this.pageModuleName].$onShow()
            } catch (e) {

            }
        })
    },
    onHide: function () {
        this.$nextTick(() => {
            try {
                this.$refs[this.pageModuleName].$onHide()
            } catch (e) {

            }
        })
    },
    onPullDownRefresh: function () {
        try {
            this.$refs[this.pageModuleName].$onPullDownRefresh()
        } catch (e) {

        }
    },
    onReachBottom: function () {
        try {
            this.$refs[this.pageModuleName].$onReachBottom()
        } catch (e) {

        }
    },
    // // 微信小程序分享(好友)
    // onShareAppMessage: function () { 
    //     return this.$refs[this.pageModuleName].getShareAppMessage()
    // },
    // // 微信小程序分享(朋友圈)
    // onShareTimeline: function () {
    //     return this.$refs[this.pageModuleName].getShareTimeline()
    // }
}
